#pragma once
#include <d3d9.h>
#include "d3dUtil.h"


class Ground
{

private:
	IDirect3DDevice9 *Device;

	IDirect3DVertexBuffer9 * vBuffer;
	IDirect3DIndexBuffer9 * iBuffer;

	LPCTSTR textureFileName;
	IDirect3DTexture9* texture;

	DWORD fvf;
	float size;

	D3DXMATRIX World;

public:
	Ground(IDirect3DDevice9 *device, float size);
	~Ground(void);

	void onLostDevice();
	void onResetDevice();

	void Render();
	void LoadTexture(LPCSTR fileName);
};

